package com.cleaningcloud.erp.domain;

import java.math.BigDecimal;
import java.util.Date;

import com.cleaningcloud.common.core.web.domain.BaseEntity;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import com.cleaningcloud.common.core.annotation.Excel;

/**
 * 应收账款对象 erp_accounts_receivable
 * 
 * @author cleaningcloud
 * @date 2024-10-02
 */
@EqualsAndHashCode(callSuper = true)
@Data
public class ErpAccountsReceivable extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 应收账款ID */
    private Long receivableId;

    /** 单据编号 */
    @Excel(name = "单据编号", sort = 3)
    private String oddNo;

    /** 单据类型(1销售单2采购退货单) */
    @Excel(name = "单据类型(1销售单2采购退货单)", sort = 2, readConverterExp = "1=销售单,2=采购退货单,3=销售退换")
    private Integer oddType;

    /** 客户/供应商ID */
    private Long businessId;

    /** 单据日期 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "单据日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", sort = 1)
    private Date oddDate;

    /** 单据状态(0未收款1已收款) */
    @Excel(name = "单据状态", sort = 13, readConverterExp = "0=未收款,1=已收款")
    private Integer oddStatus;

    /** 应收金额 */
    @Excel(name = "应收金额", sort = 7)
    private BigDecimal oddSumMoney;

    /** 实收金额 */
    @Excel(name = "实收金额", sort = 11)
    private BigDecimal oddMoney;

    /** 收款人ID */
    private Long userId;

    /** 收款人名称 */
    private String userName;

    /** 收款人方式 */
    @Excel(name = "收款人方式" ,sort = 12)
    private String payMethod;

    /** 收款时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "收款时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", sort = 10)
    private Date payTime;

    /** 备用是否关闭 */
    private String flag;

    /** 开票时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "开票时间", width = 30, dateFormat = "yyyy-MM-dd", sort = 8)
    private Date invoicingTime;

    /** 开票金额 */
    @Excel(name = "开票金额", sort = 9)
    private BigDecimal invoicingMoney;

    // 批量导出ids
    private String exportIds;


}
